<!--
//******************************************************************
//* Copyright (c) 2008 Ford Motor Company. All Rights Reserved.
//*
//*
//* $$Workfile:   economicIndexStatus.jsp  $$
//* $$Revision:   1.2  $$
//* $$Author:   TMALDON4  $$
//* $$Date:   Feb 26 2009 07:31:18  $$
//*
//* Description: Description of file goes here
//******************************************************************
-->
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-logic" prefix="logic" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://displaytag.sf.net/el" prefix="display-el" %>
<%@ taglib uri="ford-arg/tags" prefix="ft" %>

<script language="javascript">
	
	function findStatus() {
		document.EconomicIndexStatusForm.action = "EconomicIndexStatusActionFind.do";
		document.EconomicIndexStatusForm.section.value = "find";
		document.EconomicIndexStatusForm.submit();
	}
	
	function cleanFindFields() {
		document.EconomicIndexStatusForm.action = "EconomicIndexStatusActionCleanFind.do";
		document.EconomicIndexStatusForm.section.value = "cleanFind";
		document.EconomicIndexStatusForm.submit();
	}
	
	function findEconomicIndexValues(monthSelected, econSourceNumberSelected) {
		document.EconomicIndexStatusForm.action = "EconomicIndexStatusActionValuesFind.do";
		document.EconomicIndexStatusForm.monthSelected.value = monthSelected;
		document.EconomicIndexStatusForm.econSourceNumberSelected.value = econSourceNumberSelected;
		document.EconomicIndexStatusForm.submit();
	}
	
</script>

<table>
	<tr>
		<td colspan="2"><h2><bean:message key="economicIndexStatus.label.title"/></h2></td>
	</tr>
</table>
<br/>
<html:form action="/EconomicIndexStatusActionFind">
<html:hidden property="section"/>
<html:hidden property="monthSelected"/>
<html:hidden property="econSourceNumberSelected"/>
	<table>
		<tr>
			<td>
				<table>
					<tr>
						<td class="text_blue_bold align_left" colspan="100%">
							<bean:message key="costStructure.item.label.filter" />
						</td>
					</tr>
					<tr>
						<td class="text_blue_bold align_left">
							<bean:message key="economicSource"/>
						</td>						
						<td class="align_left">
							<html:select property="economicSourceSel">
								<html:option value="-1" key="label.allOption"/>
								<html:options collection="economicSources" property="eese02EconsourceNumberK" labelProperty="eese02EconsourceNameN"/>
							</html:select>
						</td>
					</tr>
					<tr>			
						<td class="text_blue_bold align_left">
							<bean:message key="economicIndexStatus.label.displayYear" />:
						</td>
						<td class="align_left">
							<html:text property="year" maxlength="4" size="4" />&nbsp;
							<html:select	property="econValueTypeSelected">
								<html:options collection="economicsTypes" property="value"
									labelProperty="label" />
							</html:select>
							<html:button property="find" onclick="cleanFindFields();" styleClass="button"><bean:message key="label.clean" /></html:button>
							<html:button property="find" onclick="findStatus();" styleClass="button"><bean:message key="label.find" /></html:button>
						</td>						
					</tr>					
				</table>
			</td>
		</tr>
		<tr>
			<td style="height:15px;" />
		</tr>
	<logic:notEmpty name="EconomicIndexStatusForm" property="year">
		<bean:define id="januaryTitle">
			<bean:message key="label.month.january.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="februaryTitle">
			<bean:message key="label.month.february.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="marchTitle">
			<bean:message key="label.month.march.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="aprilTitle">
			<bean:message key="label.month.april.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="mayTitle">
			<bean:message key="label.month.may.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="juneTitle">
			<bean:message key="label.month.june.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="julyTitle">
			<bean:message key="label.month.july.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="augustTitle">
			<bean:message key="label.month.august.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="septemberTitle">
			<bean:message key="label.month.september.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="octoberTitle">
			<bean:message key="label.month.october.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="novemberTitle">
			<bean:message key="label.month.november.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="decemberTitle">
			<bean:message key="label.month.december.abb"/><br />
			<bean:write name="EconomicIndexStatusForm" property="year" />
		</bean:define>
		<bean:define id="economicSourceTitle">
			<bean:message key="economicSource"/>
		</bean:define>		
			
		<tr>			
			<td>
				<ft:saveActivePageNumber />
				<display-el:table 	class="table1" style="width: 800px;" cellpadding="5" uid="status"
									name="sessionScope.EconomicIndexStatusForm.updateStatusCol" pagesize="15"
									excludedParams="*" requestURI="EconomicIndexStatusActionPaginate.do" >
					<display-el:column title="${economicSourceTitle}" property="economicSource.eese02EconsourceNameN" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right"/>
					<display-el:column title="${januaryTitle}" style="background-color: ${status.janStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="janUpdPercent" value="0">
							<a href="javascript:findEconomicIndexValues(1,${status.economicSource.eese02EconsourceNumberK})">						
								${status.janUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.janUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>							
						</logic:greaterThan>
						<logic:equal name="status" property="janUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(1,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>
					</display-el:column>
					<display-el:column title="${februaryTitle}" style="background-color: ${status.febStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="febUpdPercent" value="0">									
							<a href="javascript:findEconomicIndexValues(2,${status.economicSource.eese02EconsourceNumberK})">																	
								${status.febUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.febUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>
						</logic:greaterThan>
						<logic:equal name="status" property="febUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(2,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>													
					</display-el:column>
					<display-el:column title="${marchTitle}" style="background-color: ${status.marStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="marUpdPercent" value="0">									
							<a href="javascript:findEconomicIndexValues(3,${status.economicSource.eese02EconsourceNumberK})">												
								${status.marUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.marUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>
						</logic:greaterThan>
						<logic:equal name="status" property="marUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(3,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>						
					</display-el:column>
					<display-el:column title="${aprilTitle}" style="background-color: ${status.aprStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="aprUpdPercent" value="0">									
							<a href="javascript:findEconomicIndexValues(4,${status.economicSource.eese02EconsourceNumberK})">												
								${status.aprUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.aprUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>
						</logic:greaterThan>
						<logic:equal name="status" property="aprUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(4,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>						
					</display-el:column>
					<display-el:column title="${mayTitle}" style="background-color: ${status.mayStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="mayUpdPercent" value="0">								
							<a href="javascript:findEconomicIndexValues(5,${status.economicSource.eese02EconsourceNumberK})">												
								${status.mayUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.mayUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>
						</logic:greaterThan>
						<logic:equal name="status" property="mayUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(5,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>						
					</display-el:column>																									
					<display-el:column title="${juneTitle}" style="background-color: ${status.junStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="junUpdPercent" value="0">									
							<a href="javascript:findEconomicIndexValues(6,${status.economicSource.eese02EconsourceNumberK})">												
								${status.junUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.junUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>
						</logic:greaterThan>
						<logic:equal name="status" property="junUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(6,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>					
					</display-el:column>
					<display-el:column title="${julyTitle}" style="background-color: ${status.julStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="julUpdPercent" value="0">									
							<a href="javascript:findEconomicIndexValues(7,${status.economicSource.eese02EconsourceNumberK})">												
								${status.julUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.julUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>
						</logic:greaterThan>
						<logic:equal name="status" property="julUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(7,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>					
					</display-el:column>															
					<display-el:column title="${augustTitle}" style="background-color: ${status.augStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="augUpdPercent" value="0">										
							<a href="javascript:findEconomicIndexValues(8,${status.economicSource.eese02EconsourceNumberK})">												
								${status.augUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.augUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>							
						</logic:greaterThan>
						<logic:equal name="status" property="augUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(8,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>				
					</display-el:column>
					<display-el:column title="${septemberTitle}" style="background-color: ${status.sepStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="sepUpdPercent" value="0">									
							<a href="javascript:findEconomicIndexValues(9,${status.economicSource.eese02EconsourceNumberK})">												
								${status.sepUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.sepUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>							
						</logic:greaterThan>
						<logic:equal name="status" property="sepUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(9,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>						
					</display-el:column>
					<display-el:column title="${octoberTitle}" style="background-color: ${status.octStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="octUpdPercent" value="0">										
							<a href="javascript:findEconomicIndexValues(10,${status.economicSource.eese02EconsourceNumberK})">												
								${status.octUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.octUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>							
						</logic:greaterThan>
						<logic:equal name="status" property="octUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(10,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>					
					</display-el:column>
					<display-el:column title="${novemberTitle}" style="background-color: ${status.novStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="novUpdPercent" value="0">				
							<a href="javascript:findEconomicIndexValues(11,${status.economicSource.eese02EconsourceNumberK})">												
								${status.novUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.novUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>							
						</logic:greaterThan>
						<logic:equal name="status" property="novUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(11,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>							
					</display-el:column>
					<display-el:column title="${decemberTitle}" style="background-color: ${status.decStatusColor}" class="cell1 text_bold border1_right border1_top align_left" headerClass="header border_right">
						<logic:greaterThan name="status" property="decUpdPercent" value="0">
							<a href="javascript:findEconomicIndexValues(12,${status.economicSource.eese02EconsourceNumberK})">												
								${status.decUpdPercent}% <bean:message key="label.complete.abb" /><br />
								${status.decUpdAndappPercent}% <bean:message key="label.approved.abb" />
							</a>							
						</logic:greaterThan>
						<logic:equal name="status" property="decUpdPercent" value="0">
								<a href="javascript:findEconomicIndexValues(12,${status.economicSource.eese02EconsourceNumberK})"><bean:message key="label.register"/>
								</a>
						</logic:equal>
					</display-el:column>
				</display-el:table>
			</td>
		</tr>
	</logic:notEmpty>
	</table>
</html:form>